using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Student
    {
        private int stno;
        private string name;
        private int age;
        public int Stno
        {
            get { return this.stno; }
            set { this.stno = value; }
        }
        public string Name
        {
            get { return this.name; }
            set { this.name = value; }
        }
        public int Age
        {
            get { return this.age; }
            set { this.age = value; }
        }
        public Student(int stno, string name, int age)
        {
            Stno = stno;
            Name = name;
            Age = age;
        }
        public override string ToString()
        {
            return $"学号：{Stno}  姓名：{Name} 年龄：{Age}  ";
        }

    }
    class StnoSort : IComparer<Student>
    {
        public int Compare(Student x, Student y)
        {
            //if (x.Stno > y.Stno)
            //{
            //    return 1;
            //}
            //else
            //{
            //    return -1;
            //}
            return x.Stno.CompareTo(y.Stno);
        }
    }
    class NameSort : IComparer<Student>
    {
        public int Compare(Student x, Student y)
        {
            //if (x.Name > y.Name)
            //{
            //    return 1;
            //}
            //else
            //{
            //    return -1;
            //}
            return x.Name.CompareTo(y.Name);
        }
    }
    class AgeSort : IComparer<Student>
    {
        public int Compare(Student x, Student y)
        {
            //if (x.Age > y.Age)
            //{
            //    return 1;
            //}
            //else
            //{
            //    return -1;
            //}
            return x.Age.CompareTo(y.Age);
        }
    }
    /// <summary>
    /// -------------------------------------------------------------------------------------------------------------
    /// </summary>
    class ASD
    {
        private double r;
        private int c;
        private int k;
        public double R
        {
            get { return this.r; }
            set { this.r = value; }
        }
        public int C
        {
            get { return this.c; }
            set { this.c = value; }
        }
        public int K
        {
            get { return this.k; }
            set { this.k = value; }
        }

        /// <summary>
        /// 圆面积
        /// </summary>
        /// <param name="r">半径</param>
        /// <returns>圆面积</returns>
        public double aaa(double r)
        {
            this.r = r;
            return 3.14 * this.r * this.r;
        }

        /// <summary>
        /// 长方形面积
        /// </summary>
        /// <param name="c">长</param>
        /// <param name="k">宽</param>
        /// <returns>长方形面积</returns>
        public int aaa(int c, int k)
        {
            this.c = c;
            this.k = k;
            return this.c * this.k;
        }
    }



        class SumUrils
        {
            private int a;
            private int b;
            private double c;
            private double d;
            private string e;
            private string f;
            private int g;

            public int A
            {
                get { return this.a; }
                set { this.a = value; }
            }
            public int B
            {
                get { return this.b; }
                set { this.b = value; }
            }
            public double C
            {
                get { return this.c; }
                set { this.c = value; }
            }
            public double D
            {
                get { return this.d; }
                set { this.d = value; }
            }
            public string E
            {
                get { return this.e; }
                set { this.e = value; }
            }
            public string F
            {
                get { return this.f; }
                set { this.f = value; }
            }
            public int G
            {
                get { return this.g; }
                set { this.g = value; }
            }

            public int AAA(int a, int b)
            {
                this.a = a;
                this.b = b;
                return this.a + this.b;
            }
            public double AAA(double c, double d)
            {
                this.c = c;
                this.d = d;
                return this.c + this.d;
            }
            public string AAA(string e, string f)
            {
                this.e = e;
                this.f = f;
                return this.e + this.f;
            }
            public int AAA(int g)
            {
                int sum = 0;
                for (int i = 1; i <= g; i++)
                {
                    sum = sum + i;
                }
                return sum;
            }
        }
    /// <summary>
    /// -------------------------------------------------------------------------------------------------------------
    /// </summary>
    class Employee
    {
        private int id;
        private string name;
        private string mas;

        public int Id
        {
            get { return this.id; }
            set { this.id = value; }
        }
        public string Name
        {
            get { return this.name; }
            set { this.name = value; }
        }
        public string Mas
        {
            get { return this.mas; }
            set { this.mas = value; }
        }

        public void aaa()
        {
            Console.WriteLine("我的工号是{0},我的姓名是{1},我的部门是{2}", this.Id, this.Name, this.Mas);
        }
        public void bbb(int Id, string Name, string Mas)
        {
            Console.WriteLine("我的工号是{0},我的姓名是{1},我的部门是{2}", Id, Name, Mas);
        }
    }